<?php




/**
* Details of an entry in [ administrators ]
*/

$user_id = $variable->get('id', 'integer', 0); # Entity ID
$code = $variable->get('code', 'string', ''); # Protection Code

if(!$user_id)
{
	# Page was loaded without the ID parementer
	stopper::url('administrators-direct-access-error.php?context=identity');
}
else
{
	$administrators = new administrators();
	
	# Try to load the details
	if($administrators_details = $administrators->details($user_id, $code))
	{
		# We aim to reach here only.
		$smarty->assignByRef('administrators', $administrators_details);
	}
	else
	{
		# Record not found
		stopper::url('administrators-direct-access-error.php?context=data');
	}
}
?>